home *** CD-ROM | disk | FTP | other *** search
/ Belgian Amiga Club - ADF Collection / BS1 part 23.zip / BS1 part 23 / Prof page II type.adf / Install / HD_Install < prev    next >
AmigaDOS Script File  |  1990-08-10  |  2KB  |  66 lines

  1. .KEY srcName/A,srcDir/A,dest
  2. .BRA {
  3. .KET }
  4.  
  5. ; Install_Font - Install Compugraphic fonts onto a hard drive.
  6. ;
  7. ; Inputs:
  8. ;    dest    Directory to install Font into
  9. ;    srcName Name of font to install
  10. ;    srcDir  Directory containing font
  11. ;
  12. ; If first arg is "all", execute :Install/CopyAllFonts
  13. ; to install all of the fonts on the diskette.
  14. ;
  15.  
  16. ; Copy SetUpForInstall into RAM:, to reduce disk swaps while it executes.
  17. copy Type:Install/SetUpForInstall RAM:GD_InstSetupFile
  18. execute RAM:GD_InstSetupFile winch
  19. delete >nil: RAM:GD_InstSetupFile        ; Reclaim a bit of memory
  20.  
  21. ; Default (success) termination message.
  22. echo >GD_TempDir:Message " Installation complete."
  23.  
  24. ;
  25. ; Make sure that the destination exists and is a directory
  26. ;
  27. if not exists "{dest$CGFonts:}"
  28.     echo >GD_TempDir:Message "*N*E[;33m Couldn't find drawer {dest$CGFonts:}*E[m*N"
  29.     skip HDWrapup
  30. endif
  31.  
  32. instutil isdir "{dest$CGFonts:}"
  33. if warn
  34.     echo >GD_TempDir:Message "*N*E[;33m {dest$CGFonts:} is not a drawer!*E[m*N"
  35.     skip HDWrapup
  36. endif
  37.  
  38. assign GD_Dest: "{dest$CGFonts:}"
  39.  
  40. execute GD_SourceDisk:Install/UpdateUtilities
  41. if not $GDIRC eq "ok"
  42.     skip HDWrapup
  43. endif
  44.  
  45. echo "*N~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~"
  46.  
  47. ; Initialize free-space counter.
  48. instutil >GD_TempDir:free freespace GD_Dest:
  49. instutil -eGDIFREE join GD_TempDir:free
  50.  
  51. if "{srcName}" eq "all"
  52.     execute GD_SourceDisk:Install/CopyAllFonts
  53. else
  54.     execute GD_SourceDisk:Install/InsFont "{srcName}" "{srcDir}"
  55. endif
  56.  
  57. ;
  58. ; Clean up
  59. ;
  60. lab HDWrapup
  61.  
  62. echo "*N~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~*N"
  63. instutil join GD_TempDir:Message
  64.  
  65. execute GD_SourceDisk:Install/CleanUpFromInstall
  66.